package com.bianguo.android.pigeondemo.retrofit;

import io.reactivex.Observable;
import io.reactivex.annotations.NonNull;
import io.reactivex.functions.Function;

/**
 * Created by Administrator on 2018/5/18.
 */

public class BaseFunc<T> implements Function<Throwable, Observable<? extends T>> {

    @Override
    public Observable<? extends T> apply(@NonNull Throwable throwable) throws Exception {
        return Observable.error(FactoryException.analysisException(throwable));
    }
}
